﻿
namespace Schedulr.Infrastructure
{
    public class BatchHeader
    {
        public int Id { get; private set; }
        public string Name { get; private set; }

        public BatchHeader(int id, string name)
        {
            this.Id = id;
            this.Name = name;
        }

        public override string ToString()
        {
            return this.Name;
        }

        public override bool Equals(object obj)
        {
            var other = obj as BatchHeader;
            if (obj == null)
            {
                return false;
            }
            return this.Id == other.Id;
        }

        public override int GetHashCode()
        {
            return this.Id;
        }
    }
}